package com.qf.quduba.service.impl;

import com.qf.quduba.dao.ChapterDao;
import com.qf.quduba.entity.Books;
import com.qf.quduba.entity.Chapter;
import com.qf.quduba.service.ChapterService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * 作者：程意
 * 时间：2020/10/19 11:17
 */
@Service
public class ChapterServiceImpl implements ChapterService {
    @Resource
    private ChapterDao chapterDao;
    @Override
    public Chapter findChapterOne(Integer chapterId) {
        return chapterDao.findChapterOne(chapterId);
    }

    @Override
    public List<Chapter> getAllChapter(Integer bookId) {
        return chapterDao.getAllChapter(bookId);
    }

    @Override
    public int insertSelective(Chapter record) {
        return chapterDao.insertSelective(record);
    }

    @Override
    public int updatechapter(Chapter chapter) {
        return chapterDao.updatechapter(chapter);
    }


}
